package com.loren.designer.web.controller;

import com.loren.designer.utils.TestDataUtils;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@CrossOrigin
@RestController
@RequestMapping("/test-data")
public class TestDataController {

    @RequestMapping("/bar-and-line")
    public JSONObject testBigScreen01() {
        return TestDataUtils.getBarLineData();
    }

    @RequestMapping("/pie-and-pictorial-and-funnel")
    public JSONArray testBigScreen02() {
        return TestDataUtils.getPiePictorialFunnelData();
    }

    @RequestMapping("/scatter")
    public JSONArray testBigScreen03() {
        return TestDataUtils.getScatterData();
    }

    @RequestMapping("/radar")
    public JSONObject testBigScreen04() {
        return TestDataUtils.getRadarData();
    }

    @RequestMapping("/gauge")
    public JSONObject testBigScreen05() {
        return TestDataUtils.getGaugeData();
    }

    @RequestMapping("/map")
    public JSONArray testBigScreen06() {
        return TestDataUtils.getMapData();
    }

    @RequestMapping("/text-and-marquee")
    public JSONObject testBigScreen07() {
        return TestDataUtils.getTextMarqueeData();

    }

    @RequestMapping("/table")
    public JSONArray testBigScreen08() {
        return TestDataUtils.getTableData();
    }

}
